/*
 * @Author: 9ilk 3535851673@qq.com
 * @Date: 2025-03-18 19:55:44
 * @LastEditors: 9ilk 3535851673@qq.com
 * @LastEditTime: 2025-03-19 23:12:12
 * @FilePath: /zhuang/ETEpollServer/Main.cc
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */

 #include <iostream>
 #include <string>
 #include "Log.hpp"
 #include "Listener.hpp"
 #include "Connection.hpp"
 #include "Reactor.hpp"
 
 using namespace LogModule;
 
 int main(int argc, char *argv[])
 {
     if (argc != 2)
     {
         std::cout << "Usage: " << argv[0] << " port" << std::endl;
         return 1;
     }
     ENABLE_CONSOLE_LOG();
     uint16_t local_port = std::stoi(argv[1]);
     Reactor reactor;
     auto conn = std::make_shared<Listener>(local_port);
     reactor.InsertConnection(conn);
     reactor.loop();
 
     return 0;
 }